{template 'common/header-base'}
{if user_is_vice_founder($_W['uid']) && $_W['iscontroller']}
{template 'common/header-vice'}
{else}
<div class="skin-2 {if !$_W['iscontroller']}skin-2--full{/if}" data-skin="2">
	<div class="skin-2__right">
		<!--前后端分离去除顶部显示-->
		{if !empty($_W['setting']['copyright']['local_install'])}
		<div class="skin-2__header">
			<div class="shortcut pull-left dropdown ">
				<div class="shortcut-header" data-target="#" data-toggle="dropdown" ><i class="wi wi-menu-setting"></i>菜单</div>
				<ul class="shortcut-list ">
					<li class="shortcut-item">
						{loop $top_nav_shortcut $nav}
						<div class="parent">
							<a href="{if empty($nav['url'])}{php echo url('home/welcome/' . $nav['name']);}{else}{$nav['url']}{/if}">
								<i class="{$nav['icon']} icon"></i>{$nav['title']}
							</a>
						</div>
						{/loop}
					</li>
					{php $shortcut_menu = system_shortcut_menu()}
					{loop $shortcut_menu $menu}
					{if !empty($menu['section'])}
					<li class="shortcut-item">
						<div class="parent">
							<a href="{$menu['url']}">
								<i class="{$menu['icon']} icon"></i>{$menu['title']}
							</a>
						</div>
						<div class="child">
							{loop $menu['section'] $section}
								{if !isset($section['is_display']) || !empty($section['is_display'])}
									{loop $section['menu'] $nav}
										{if !empty($nav['is_display'])}
										<div class="item text-over">
											<a href="{$nav['url']}">
												<i class="{$nav['icon']} icon"></i>{$nav['title']}
											</a>
										</div>
										{/if}
									{/loop}
								{/if}
							{/loop}
						</div>
					</li>
					{/if}
					{/loop}
				</ul>
				<div class=""></div>
			</div>
			{if !$_W['iscontroller']}
			<div class="header-info-common pull-left">
				<a class="header-info-common__logo" href="javascript:;" onclick="goToHome()">
					<img src="{if $_W['isw7_sign']}//cdn.w7.cc/ued/logo/console.png{else}{if !empty($_W['setting']['copyright']['blogo'])}{php echo to_global_media($_W['setting']['copyright']['blogo'])}{else}./resource/images/logo/logo.png{/if}{/if}" class="logo" style="max-height: {if $_W['isw7_sign']}unset{else}40px{/if};max-width: {if $_W['isw7_sign']}unset{else}100px;{/if}">
				</a>
				<script>
					var goToHome = function() {
						{if $_W['isw7_sign']}
						if(window.parent) {
							window.parent.postMessage({goHome: 2}, '*')
						}
						{else}
							location.href = "{php echo $_W['siteroot'] . 'web/home.php'}";
						{/if}
					}
				</script>
				{if !empty($_W['breadcrumb'])}
				<div class="header-info-common__breadcrumb">
					<a href="{$_W['siteroot']}web/home.php" class="home">
						<i class="wi wi-home"></i>
					</a>
					<span class="separator"> <i class="wi wi-angle-right"></i> </span>
					<div class="item">{$_W['breadcrumb']}</div>
				</div>
				{/if}
			</div>
			{/if}
			{if !empty($_W['uid'])}
			<ul class="user-info">
				{template 'common/header-topright'}
			</ul>
			{else}
			<ul class="user-info">
				<li class="dropdown"><a href="{php echo url('user/register/register_url');}">注册</a></li>
				<li class="dropdown"><a href="{php echo url('user/login');}">登录</a></li>
			</ul>
			{/if}
		</div>
		{/if}
		<!--前后端分离去除顶部显示-->
		<div class="skin-2__content main">
			{if !defined('IN_MESSAGE')}
				{php $_GPC['a'] = empty($_GPC['a']) ? '' : $_GPC['a'];}
				{if !empty($frames['dimension']) && $frames['dimension'] == 3 && in_array(FRAME, array('account', 'system', 'advertisement', 'wxapp', 'site', 'webapp', 'phoneapp')) && !in_array($_GPC['a'], array('news-show', 'notice-show', 'notice-news'))}
				<div class="skin-2__sub">
					<div class="sub-top">
						<!-- 模块信息 -->
						{if !empty($_GPC['module_name']) && !in_array($_GPC['module_name'], array('keyword', 'special', 'welcome', 'default', 'userapi', 'service', 'apply')) || defined('IN_MODULE') && IN_MODULE != ''}
						<div class="apply-fixed-top">
							{template 'common/header-module'}
						</div>
						<!-- 模块信息 -->
						{else}
						<div class="left-menu-top-panel">
							{template 'common/header-' . FRAME}
						</div>
						{/if}
					</div>
					
					<!-- 二级菜单-->
					<div class="js-menu" id="js-menu-{FRAME}{$_W['account']['uniacid']}">
					{loop $frames['section'] $frame_section_id $frame_section}
						
						{if !isset($frame_section['is_display']) || !empty($frame_section['is_display'])}
						<div class="panel panel-menu">
							{if !empty($frame_section['title'])}
							<div class="panel-heading">
								<span class="{if !empty($_GPC['menu_fold_tag']) && $_GPC['menu_fold_tag'] !== $frame_section_id || empty($_GPC['menu_fold_tag']) && 'platform_module' !== $frame_section_id}collapsed{/if}" data-toggle="collapse" data-parent="#js-menu-{FRAME}{$_W['account']['uniacid']}" data-target="#frame-{$frame_section_id}" onclick="util.cookie.set('menu_fold_tag', util.cookie.get('menu_fold_tag') == '{$frame_section_id}' ? '' : '{$frame_section_id}')">
									<span class="nav-title">{$frame_section['title']}<i class="wi wi-angle-down pull-right setting"></i></span>
								</span>
							</div>
							{/if}
							<ul class="list-group {if !empty($frame_section['title'])}collapse{/if} {if $_GPC['menu_fold_tag'] === $frame_section_id || empty($_GPC['menu_fold_tag']) && 'platform_module' === $frame_section_id}in{/if}" id="frame-{$frame_section_id}" >
								{loop $frame_section['menu'] $menu_id $menu}
									{if !empty($menu['is_display'])}
										{if $menu_id == 'platform_module_plugin_more' || $menu_id == 'platform_module_more'}
										<li class="list-group-item">
											<a href="{php echo $menu['url']}" class="text-over" {if $_W['isw7_sign'] && $frame_section_id == 'platform_module_menu'}target="_blank"{/if}>
												<span class="nav-icon" ><span class="icon-more"><i class="wi wi-plus"></i></span></span>
												<span class="nav-title">{$menu['title']}</span>
											</a>
										</li>
										{else}
										{if !empty($menu['active'])}{php $active_sub_permission = empty($menu['sub_permission']) ? array() : $menu['sub_permission'];}{/if}
										<li class="list-group-item list-group-item-plugin {if !empty($menu['multilevel'])}list-group-item-more{/if} {if !empty($menu['active'])}active{/if}">
											{if $frame_section_id == 'platform_module_plugin' && !empty($_GPC['m']) && $_GPC['m'] != $menu['main_module']}
											<a class="back" href="{php echo url('module/welcome', array('m' => $menu['main_module'], 'uniacid' => $_W['uniacid']))}" >
												<i class="wi wi-angle-left"></i>
											</a>
											{/if}
											<a href="{if !empty($menu['multilevel'])}javascript:;{else}{$menu['url']}{/if}" {if $_W['isw7_sign'] && in_array($frame_section_id, array('platform_module_menu')) && !$menu['multilevel']}target="_blank"{/if} {if !empty($menu['multilevel'])}data-toggle="collapse" data-target="#frame-child-{$frame_section_id}-{$menu_id}"{/if} class="text-over">
												<span class="nav-icon" >
													{if $frame_section_id == 'platform_module' || $frame_section_id == 'platform_module_plugin'}
													<img src="{$menu['icon']}"/>
													{else}
													<i class="{$menu['icon']}"></i>
													{/if}
												</span>
												<span class="nav-title">{$menu['title']}{if !empty($menu['multilevel'])}<i class="wi wi-angle-down pull-right setting"></i>{/if}</span>
											</a>
											{if !empty($menu['multilevel']) && !empty($menu['childs'])}
											<ul class="list-child collapse in" id="frame-child-{$frame_section_id}-{$menu_id}">
												{loop $menu['childs'] $module_menu_child}
												<li class="list-child-item {if $module_menu_child['active']}active{/if}">
													<a href="{$module_menu_child['url']}" class="text-over" {if $_W['isw7_sign']}target="_blank"{/if}>
														<span class="nav-title">{$module_menu_child['title']}</span>
													</a>
												</li>
												{/loop}
											</ul>
											{/if}
										</li>
										{/if}
									{/if}
								{/loop}
							</ul>
						</div>
						{/if}

					{/loop}
					</div>
					<!-- end二级菜单-->
				</div>
				{/if}
				<div class="skin-2__container container">
						<div class="content {if !empty($_W['page']['title']) && !empty($_GPC['iscontroller'])}is-main-page{/if}">
						{if !empty($_W['page']['title']) && $frames['title'] != '首页' && !empty($frames['title']) && !defined('IN_MODULE') && $_W['iscontroller']}
							<div class="we7-page-title {if empty($have_right_content_menu)} hidden{/if}">{$_W['page']['title']}</div>
						{/if}
						{if !empty($frames['dimension']) && $frames['dimension'] == 2}
							<!-- start消息管理菜单特殊,走自己的we7-page-tab,故加此if判断;平台/应用/我的账户无we7-page-table -->
							{if !in_array(FRAME, array('message', 'platform', 'module', 'myself', 'workorder'))}
							<ul class="we7-page-tab {if empty($have_right_content_menu)} hidden{/if}">
								{php $have_right_content_menu = 0;}
								{loop $frames['section'][FRAME]['menu'] $menu_id $menu}
									{if in_array(FRAME, array('account_manage', 'permission'))}
									{if permission_check_account_user('see_' . $menu['permission_name'])}
									<li class="{if !empty($menu['active'])}active{/if}"><a href="{$menu['url']}&iscontroller=1">{$menu['title']}</a></li>
									{/if}
									{else}
									<li class="{if $menu['active']}active{/if}">
										<a href="{$menu['url']}&iscontroller=1">
											{$menu['title']}
										</a>
									</li>
									{/if}
									{if !empty($menu['active'])}{php $have_right_content_menu = 1;}{/if}
								{/loop}
							</ul>
							{/if}
							<!-- end用户管理菜单和消息管理菜单特殊,走自己的we7-page-tab;平台/应用/我的账户无we7-page-table -->
						{/if}
			{/if}
{/if}